<template>
  <div class="topbox">
    <div class="boxzhifu">
      <svg t="1691909403958" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"
           p-id="4015" width="200" height="200">
        <path
            d="M0 512C0 229.234759 229.234759 0 512 0s512 229.234759 512 512-229.234759 512-512 512S0 794.765241 0 512z m419.310345 194.630621a35.310345 35.310345 0 0 0 49.399172 1.271172l335.518897-311.931586a35.310345 35.310345 0 0 0-48.075035-51.729655l-309.124413 289.544827-145.125518-149.645241a35.310345 35.310345 0 1 0-50.688 49.169655l168.112552 173.320828z"
            fill="#389BFF" p-id="4016"></path>
      </svg>
      <!--    <img src="./05bf98377d2263141a6e66ec23fa9b4.png" alt="支付成功">-->

    </div>
    <div id="box">{{ count }}秒后关闭该页面</div>
  </div>
</template>

<script>
export default {
  name: "PaySuccess",
  data() {
    return {
      count: 5,
    }
  },
  methods: {
    close() {
      setInterval(() => {
        this.count--;
        if (this.count < 0) {
          clearInterval()
          window.close()
        }
      }, 1000)
    }
  },
  mounted() {
    this.close()
  }
}
</script>

<style scoped>
* {
  margin: 0;
  padding: 0;
}

.boxzhifu {
  width: 100px;
  height: 100px;
  margin: 0 auto;
  padding: 150px 0 0 0;
}

.boxzhifu svg {
  width: 100px;
  height: 100px;
  /* margin: 0 auto; */
}

#box {
  width: 150px;
  height: 30px;

  text-align: center;
  /* border: 1px red solid; */
  margin: 20px auto;
}
.topbox{
  margin: 0 auto;
  background: #ffff;
  width: 1200px;
  //height: 850px;

}
</style>